﻿        var myData = "";
        function capturePhotoEdit(source) {
            navigator.camera.getPicture(onPhotoDataSuccess, onFail, {
                quality: 50,
                destinationType: destinationType.DATA_URL,
                sourceType: source
            });
        }

        function onFail(message) {
            alert('Failed because: ' + message);
        }

        function onPhotoDataSuccess(imageData) {

            //alert(imageData);

            var smallImage = document.getElementById('smallImage');

            smallImage.style.display = 'block';

            smallImage.src = "data:image/jpeg;base64," + imageData;
            myData = imageData;

        }